package com.dy.lock.screen.service.impl;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.dy.lock.screen.dao.LockScreenDao;
import com.dy.lock.screen.pojo.LockScreenInfo;
import com.dy.lock.screen.scoket.Head;
import com.dy.lock.screen.service.LockScreenService;

@Service("lockScreenService")
public class LockScreenServiceImpl implements LockScreenService {
	@Resource(name = "lockScreenDao")
	private LockScreenDao lockScreenDao;

	@Override
	public List<LockScreenInfo> query(String type, Integer pageStart,
			Integer pageEnd, Head head) {
		// TODO Auto-generated method stub
		Map<String, Object> paramMap = new HashMap<String, Object>();
		paramMap.put("pageStart", pageStart);
		paramMap.put("pageEnd", pageEnd);
		if ("-1".equals(type) || "0".equals(type)) {
			paramMap.put("type", type);
		} else {
			paramMap.put("picType", type);
		}
		return this.lockScreenDao.queryT(paramMap);
	}

}
